home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.20021006-20030409 / 000125_jhaines@benplan.com_Mon Dec 2 16:43:00 EST 2002.msg < prev    next >
Text File  |  2020-01-01  |  3KB  |  89 lines

  1. Article: 13906 of comp.protocols.kermit.misc
  2. Path: newsmaster.cc.columbia.edu!panix!nycmny1-snh1.gtei.net!news.gtei.net!bloom-beacon.mit.edu!newsfeed.stanford.edu!postnews1.google.com!not-for-mail
  3. From: jhaines@benplan.com (John Haines)
  4. Newsgroups: comp.protocols.kermit.misc
  5. Subject: Using C-KERMIT to ftp on a PPP dail-up connection
  6. Date: 2 Dec 2002 12:11:17 -0800
  7. Organization: http://groups.google.com/
  8. Lines: 71
  9. Message-ID: <684be77d.0212021211.49438037@posting.google.com>
  10. NNTP-Posting-Host: 216.136.79.238
  11. Content-Type: text/plain; charset=ISO-8859-1
  12. Content-Transfer-Encoding: 8bit
  13. X-Trace: posting.google.com 1038859878 28442 127.0.0.1 (2 Dec 2002 20:11:18 GMT)
  14. X-Complaints-To: groups-abuse@google.com
  15. NNTP-Posting-Date: 2 Dec 2002 20:11:18 GMT
  16. Xref: newsmaster.cc.columbia.edu comp.protocols.kermit.misc:13906
  17.  
  18. I have been reading the C-KERMIT 8.0 reference and the FAQ, but still
  19. having trouble putting the whole picture together.
  20.  
  21. I have been using C-KERMIT on AIX for about a year.  I need to
  22. transfer a file to another company.   They provide access to their FTP
  23. server via PPP dial-up.  I am wondering can I use C-KERMIT to dail the
  24. number, redirect to PPP, and then transfer the file using kermit
  25. commands, and close the connection.  In the examples from the C-KERMIT
  26. documentation, I noticed they redirect to the pppd daemon, but in AIX
  27. I could only find the pppattachd command to invoke the ppp daemon. 
  28. Any help would be appreciated, because at this point I'm not sure what
  29. is possible and what is not possible.  I would prefer to accomplish
  30. the whole task using C-KERMIT, but don't know if it is possible.  Any
  31. assistance would be appreciated.  Thanks in advance for the
  32. enlightenment!
  33.  
  34.  
  35. Below is the script that I have developed thus far.
  36.  
  37. #!/usr/opt/ckermit/ckermit +
  38. set telnet echo remote
  39. set host 10.44.16.3 7001
  40. set modem type generic
  41. set dial hangup off
  42. set exit on-disconnect on
  43. set ftp AUTOAUTHENTICATION ON
  44. set ftp AUTOLOGIN ON
  45. set ftp VERBOSE ON
  46. set ftp DEBUG ON
  47.  
  48. ; Setup modem pool information
  49. .telephone      = 9,1-210-226-3232
  50. define  modem_userid    user
  51. define  modem_passwd    userpasswd
  52.  
  53. assign \%u \m(modem_userid)
  54. assign \%p \m(modem_passwd)
  55.  
  56. ; Logon to the modem pool
  57. lineout
  58. sleep 1
  59. lineout
  60. promptwait \m(wait_time) Username:
  61. if fail faterr 1 "ERROR: Can't login to the modem pool. "
  62. lineout \%u
  63.  
  64. promptwait \m(wait_time) Password:
  65. if fail faterr 1 "ERROR: Can't login to the modem pool. "
  66. lineout \%p     ; Send password
  67. undef \%p       ; Clear password from memory
  68.  
  69. ; Dail customer number
  70. dial \m(telephone)
  71.  
  72. ; Once connected redirect connection to PPP on AIX
  73. exec /redirect /usr/sbin/pppattachd demand
  74.  
  75. ; Connect to remote customer IP Address
  76.  
  77. ftp open ftp.mycustomer.com 21 /user:kuser /password:passwd
  78. if fail exit 1 Connection failed:  \v(ftp_message)
  79.  
  80. if not \v(ftp_loggedin) exit 1 Login failed
  81.  
  82. ftp dir
  83.  
  84. ftp put /binary benplan.ini
  85. if fail exit 1 ftp PUT benplan.ini : \v(ftp_message)
  86.  
  87. ftp bye
  88. exit
  89.